<#assign ctx=request.contextPath />
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
    <title>流程实例列表</title>
<link rel="stylesheet" href="${ctx}/css.css">
</head>
<body>
<div style="height:0;"><a name="gotop">&nbsp;</a></div>
<div class="top">
    <a href="${ctx}/hello" class="backtrack"><img src="${ctx}/0.png"></a>
    <a href="javascript:history.back();" class="return"><img src="${ctx}/12.png"></a>
    <div class="box">
        流程实例列表
    </div>
</div>
<div class="empty"></div>

<#if (errors?? && errors?size>0)>
<ul class="hint">
    <#list errors as err>
        <li>${err}</li>
    </#list>
</ul>
</#if>
<p class="show"><b>有${pinstList?size!""}个正在进行的流程:</b></p>

<#list pinstList as pinst>
<table class="list_box">


    <tr hidden>
        <td class="lo_3">ID</td>
        <td class="lo_4">${pinst.id}</td>
    </tr>

    <tr class="lo_7">
       <td class="lo_3">实例名称</td>
       <td class="lo_4">${pinst.name!""}</td>
    </tr>

    <tr style="display:none">
        <td class="lo_3">状态</td>
        <td class="lo_4">${pinst.status!""}</td>
    </tr>

    <tr style="display:none">
        <td class="lo_3">开始时间</td>
        <td class="lo_4">${(pinst.startDate?datetime)!""}</td>
    </tr>

    <tr style="display:none">
        <td class="lo_3">发起人</td>
        <td class="lo_4">${pinst.initiator!""}</td>
    </tr>



    <tr hidden>
         <td class="lo_3">模板ID</td>
         <td class="lo_4">${pinst.processDefinitionId}</td>
    </tr>

    <tr>
         <td class="lo_3">模板KEY</td>
         <td class="lo_4">${pinst.processDefinitionKey}</td>
    </tr>

    <tr>
         <td class="lo_3">业务KEY</td>
         <td class="lo_4">${pinst.businessKey!""}</td>
    </tr>

    <tr style="display:none">
         <td class="lo_3">描述</td>
         <td class="lo_4">${pinst.description!""}</td>
    </tr>
    <tr>
        <td class="lo_3">任务</td>
        <td class="lo_4 lo_10"><a href="${ctx}/lossMng/subtaskList/${pinst.id}">子任务</a></td>
    </tr>
    <tr>
         <td class="lo_3">进展图</td>
        <#if pinst.processDefinitionKey?starts_with("procAlterMeter")>
            <td class="lo_4 lo_10"><a href="${ctx}/alterMeter/currentDiagram/${pinst.id}">进展图</a></td>
        <#elseif pinst.processDefinitionKey?starts_with("procSetupMeter")>
            <td class="lo_4  lo_10"><a href="${ctx}/setupMeter/currentDiagram/${pinst.id}">进展图</a></td>
        <#else>
            <td class="lo_4 lo_10"><a href="${ctx}/lossMng/currentDiagram/${pinst.id}">进展图</a></td>
        </#if>
    </tr>

    <tr>
         <td class="lo_3">挂起</td>
         <td class="lo_4 lo_9"><a href="${ctx}/lossMng/suspendInst/${pinst.id}">挂起</a></td>
    </tr>

    <tr>
         <td class="lo_3">删除！</td>
         <td class="lo_4 lo_9">
            <#if pinst.processDefinitionKey?starts_with("procSetupMeter")>
                <a href="${ctx}/setupMeter/deleteInst/${pinst.id}">删除</a>
            <#else>
                <a href="${ctx}/lossMng/deleteInst/${pinst.id}">删除</a>
            </#if>
        </td>
    </tr>

</table>
<br/>
</#list>

<div class="go">
	<a title="返回顶部" class="top_1" href="#gotop"></a>
	<a title="返回首页" class="feedback" href="${ctx}/hello"></a>
	<a title="返回底部" class="bottom" href="#gobottom"></a>
</div>
<div style="height:0;"><a name="gobottom">&nbsp;</a></div>

</body>
</html>